<ui:composition template="/template/template.xhtml"
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:p="http://primefaces.org/ui">

    <ui:define name="logo">
        <div class="item">
            <h:graphicImage value="/avatar/#{loginMB.userSession.avatar}" />
                <h3><h:outputText value="Bem vindo #{loginMB.userSession.nome}" /></h3>
         </div>   
    </ui:define>
    
    <ui:define name="item-menu">
        <h:form>
        <h:link value="Administrativo" outcome="administrativo/index.xhtml" rendered="#{loginMB.userSession.admin}" />
        <h:link value="Academico" outcome="academico/index.xhtml" rendered="#{loginMB.userSession.academico}" />
        <h:commandLink id="logout" action="#{loginMB.logout}" value="Logout"></h:commandLink>
        </h:form>
    </ui:define>
    
    <ui:define name="logo-curso">
    <p:messages id="messages" showDetail="false" autoUpdate="true" closable="true" globalOnly="true"/> 
    <h:outputText value="Olá #{loginMB.userSession.nome}" />
    </ui:define>
</ui:composition>
